import React from 'react'
import './coupon.css'
export default function Coupon(props) {
    let {coupon}=props
    // console.log(coupon)
    return (
        <div className='Coupon'>
            <h3>优惠券</h3>
            {
                coupon?coupon.map(item=>(
                    item.content.map(val=>(
                        <div className='Coupon_box' key={val.id}>
                            <p className='Coupon_box_h'>{val.title}</p>
                            <div>{val.description}</div>
                            <div>开始时间：{val.begintime}</div>
                            <div>结束时间：{val.endtime}</div>
                            <div>￥{val.money}元</div>
                        </div>
                    ))
                )):null
            }
        </div>
    )
}